% Head() Select Case Lcase(request.querystring("Action")) Case"edituser" CheckString "21" EditUser Case"saveuser" CheckString "21" SaveUser Case"adminok" AdminOK Case"executesql" CheckString "56" ExecuteSql Case"sqlpassword" CheckString "56" SqlPassword End select Footer() Sub SqlPassword Dim NewP,OldP NewP=MNBoard.Fun.GetStr("new") oldP=MNBoard.Fun.GetStr("old") If NewP="" And oldP="" then Showtable"更改执行SQL语句的密码","
" Else If newP="" or oldP="" then goback"","":Exit Sub If MNBoard.Execute("Select * From [i_Config] where SqlPassword='"&MD5(oldP)&"'").Eof Then Goback"","修改失败,原密码不正确!":Exit Sub MNBoard.Execute("update [i_Config] Set SqlPassword='"&MD5(newP)&"'") MNBoard.netLog"操作后台_更改执行SQL语句的密码" Suc "","成功更改执行SQL语句的密码!","?Action=ExecuteSql" End If End Sub Sub ExecuteSql Dim Sql,Password,Caption,Content,S Sql=Request.Form("sql") Password=MNBoard.Fun.GetStr("password") Caption="执行SQL语句" Content="" ShowTable Caption,Content If Sql<>"" then If Password="" Then Goback"","":Exit Sub If MNBoard.Execute("Select * From [i_Config] where SqlPassword='"&MD5(Password)&"'").Eof Then Goback"","密码错误":Exit Sub On Error Resume Next MNBoard.Execute(Sql) If err.number=0 then Caption="执行成功":Content="